<template>
  <div class="doctor-title">
    <div class="register-record">
      <p class="register-record-text">患者信息:</p>
      <el-tag type="primary">姓名:{{registRecord.realName}}</el-tag>
      <el-tag type="primary">病历号:{{registRecord.caseNumber}}</el-tag>
      <el-tag type="primary">年龄:{{registRecord.age}}</el-tag>
      <el-tag type="primary">性别:{{registRecord.gender}}</el-tag>
    </div>
    <DoctorHeader :titleText="props.titleText" />
  </div>
</template>

<script setup>
import { RegisterStore } from '@/stores/counter'
import DoctorHeader from './header'
const props = defineProps(['titleText']) // 接收父组件传值
const registerStore = RegisterStore()
const registRecord = registerStore.get()
</script>

<style scoped lang="scss">
.register-record {
  display: flex;
  height: 30px;
  align-items: center;
  .register-record-text {
    font-size: 0.8rem;
  }
}
</style>
